#ifndef FONT_H
#define FONT_H

#include <GL/gl.h>
#include <string>

using namespace std;

struct Letter {
	int w, h;
	int left, top, advancex;
	GLuint tex;
};


class Font {
private:
	int size;
	int maxAdvanceY;
public:
	Letter letters[128];
	Font(const char *fname, int size = 16 );
	void writeLetter(unsigned char ch, int x, int y);
	void writeString(string s, int x, int y);
	// This returns how many pixels the string will take up based on Letter.advancex
	int widthOfString( string s );
	int getMaxAdvanceY() { return maxAdvanceY; }

};

#endif
